package api;

import conf.App;
import utils.HttpClientUtils;
import utils.ResponseData;

import java.io.IOException;
import java.net.URISyntaxException;
import java.util.HashMap;
import java.util.Map;

public class LoginApi {
    private static final String LoginUrl= App.BaseUrl+"system/public/verifyLogin";
    public ResponseData login(String name,String password,String code) throws IOException, URISyntaxException {
        Map<String,String> map=new HashMap<>();
        map.put("username",name);
        map.put("password",password);
        map.put("valicode",code);
        return HttpClientUtils.post_form(LoginUrl,map);

    }
}
